<template>
	<view class="terms-container">
		<!-- 服务条款/隐私协议 -->
		 <rich-text :nodes="content"></rich-text>
	</view>
</template>

<script>
	var http = require("@/utils/http.js");
	export default {
		data() {
			return {
				content:''
			}
		},
		onLoad:function(options){
			this.ServiceTermsConfig(options.sts)
		},
		computed:{
			i18n() {
				return this.$t('index')
			}
		},
		methods: {
			/*
			key = 'service-terms'代表服务条款，key = 'service-policy'代表隐私策略
			*/
			ServiceTermsConfig(key) {
				let data;
				let params = {
					url: '/sys/config/info/' + key,
					method: "GET",
					callBack:res =>{
						// console.log(res)
						
						this.setData({
							content:res
						})
					}
				}
				http.request(params)
			}
		}
	}
</script>

<style>
@import url("./termsPage.css");
</style>
